<?php

namespace Sharks\Core\Support\Cache;

/**
 * Cache工厂类
 */
class CacheFactory {

    public static function instance($name = 'file', $options = null) {
        $methodName = $name . "Cache";
        return self::$methodName($options) ;
    }

    public static function fileCache($options = null) {
        $fileCacheFactory = new FileCacheFactory($options);
        return $fileCacheFactory->instance();
    }
}